/** A test striker option without common decision */
option(Striker)
{
    float p = -2.0f;
    static float ydistance = 0.f;
//    ArmContact();
    initial_state(walkStraight)
    {
        transition
        {
            if(theLibCodeRelease.odometryXSum >= 6530.f)
	   // if(state_time > 30)
        	goto choose;
		
        }
        action
        { 
		WalkAtRelativeSpeed(Pose2f(p * theLibCodeRelease.odometryRSum, 0.8f, 0.f));
		//WalkAtRelativeSpeed(Pose2f(0.f, 0.8f, 0.f));
        }
    }
    state(choose)
    {
	transition
	{
		for(int i = 0; i < (int)theObstacleModel.obstacles.size(); i++)
		{
			if(theObstacleModel.obstacles[i].isTeammate() == true)
			{
					ydistance = theObstacleModel.obstacles[i].center.y();
					goto adjust;
			}
		}
		goto pass;
	}
    }
    state(adjust)
    {
	transition
	{
		if(state_time > 15000)
			goto pass;
		for(int j = 0; j < (int)theObstacleModel.obstacles.size(); j++)
		{
			if(theObstacleModel.obstacles[j].isTeammate() == true)
			{
				if(std::abs(theObstacleModel.obstacles[j].center.y()+90.f) < 20.f)
					goto pass;
			}
		}
		
	}	
	action
	{
				WalkToTarget(Pose2f(0.3f,0.3f,0.3f),Pose2f(0.f,0.f,ydistance+90.f));
	}
    }
    state(pass)
    {
	transition
	{
		if(action_done)
		  goto finish;
	}
        action
	{
            Stand();
	    SpecialAction(SpecialActionRequest::keeperJumpLeftPenalty);	
	}
    }
    
	state(finish)
	{
		action
		{
			Stand();
		}
	}
}
